package cn.wolfcode.trip.base.mapper;

import cn.wolfcode.trip.base.domain.Credit;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CreditMapper {
    int deleteByPrimaryKey(Long id);

    int insert(Credit entity);

    Credit selectByPrimaryKey(Long id);

    List<Credit> selectAll();

    int updateByPrimaryKey(Credit entity);

    Credit selectByUserId(Long userId);

    void update(@Param("userId") Long userId, @Param("totalCredits") int totalCredits);
}